import Mock from 'mockjs'

export default {
  getHomeData: () => {
    return {
      code: 2000,
      data: {
        tableData: [
          {
            name: '三星',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          },
          {
            name: '诺基亚',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          },
          {
            name: 'OPPO',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          },
          {
            name: '苹果',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          },
          {
            name: '小米',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          },
          {
            name: '华为',
            todayBuy: Mock.Random.float(100, 1000, 0, 2),
            monthBuy: Mock.Random.float(1000, 10000, 0, 2),
            totalBuy: Mock.Random.float(10000, 100000, 0, 2)
          }
        ],
        orderData: {
          data: [
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            },
            {
              三星: Mock.Random.float(100, 10000, 0, 2),
              诺基亚: Mock.Random.float(100, 10000, 0, 2),
              OPPO: Mock.Random.float(100, 10000, 0, 2),
              苹果: Mock.Random.float(100, 10000, 0, 2),
              小米: Mock.Random.float(100, 10000, 0, 2),
              华为: Mock.Random.float(100, 10000, 0, 2)
            }
          ],
          date: ['20191001', '20191002', '20191003', '20191004', '20191005', '20191006', '20191007']
        },
        userData: [
          {
            date: '周一',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周二',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周三',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周四',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周五',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周六',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          },
          {
            date: '周日',
            new: Mock.Random.integer(100, 800),
            active: Mock.Random.integer(0, 200)
          }
        ],
        videoData: [
          {
            name: '三星',
            value: Mock.Random.float(1000, 10000, 0, 2)
          },
          {
            name: '诺基亚',
            value: Mock.Random.float(1000, 10000, 0, 2)
          },
          {
            name: 'OPPO',
            value: Mock.Random.float(1000, 10000, 0, 2)
          },
          {
            name: '苹果',
            value: Mock.Random.float(1000, 10000, 0, 2)
          },
          {
            name: '小米',
            value: Mock.Random.float(1000, 10000, 0, 2)
          },
          {
            name: '华为',
            value: Mock.Random.float(1000, 10000, 0, 2)
          }
        ]
      }
    }
  }
}
